FROM python:3.13-slim
COPY --from=docker.io/astral/uv:latest /uv /uvx /bin/

# Create app directory
WORKDIR /app

# Install app dependencies
COPY . /app

RUN apt update && apt install -y --no-install-recommends gcc &&\
    uv sync
# RUN pip config set global.index-url http://mirrors.aliyun.com/pypi/simple/
# RUN pip config set global.index-url https://mirrors.cloud.tencent.com/pypi/simple/ &&\
#     python -m pip install --upgrade pip &&\
#     pip install uv &&\
    # pip install --no-cache-dir -r requirements.txt
# RUN pip install -r requirements.txt

# 第二个阶段 - 最终镜像
# FROM python:3.12-slim

# COPY --from=builder /app /app
# WORKDIR /app

# Bundle app source

# EXPOSE 8080

# CMD [ "python","-u","snr.py" ]
CMD [ "uv","run","snr.py" ]
